More iOS6 Development by Alex Horovitz & Kevin Kim & Jeff LaMarche & David Mark

More iOS6 Development by Alex Horovitz & Kevin Kim & Jeff LaMarche & David Mark

Author:Alex Horovitz & Kevin Kim & Jeff LaMarche & David Mark
Language: eng
Format: epub
ISBN: 9781430238072
Publisher: Apress


Table 9-1. Game Space Locations, Sizes, and Tags

Okay, you’ve defined your interface, now let’s connect it to your controller. While still in Interface Builder, change the Editor from Standard to Assistant view in the Toolbar. The Editor pane should split horizontally, with Interface Builder on the left, and the Source Code Editor, open to ViewController.h, on the right. You want to add Outlets for the New Game button and Label you placed on top of it. If you control-drag from the middle of the New Game button, the Outlet pop-up should automatically set the Type field to UILabel. That means you’re adding an Outlet for the Label. Name it feedbackLabel and click Connect.

You need to add an Outlet for the New Game button you created as well, but it’s essentially blocked by the feedbackLabel. Open the disclosure triangle on the bottom left of the Interface Builder Editor pane, and expand the Object Dock on the left (Figure 9-14). In the Objects group, underneath the View (if it’s not open, open it), find the New Game button object named Button. Control-drag from Button to just below the feedbackLabel Outlet and create a new Outlet. Name it gameButton and click Connect.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.